import java.util.Scanner;

public class false_demo {
    public static void main(String[] args) {
        int count = 0;

        Scanner scanner = new Scanner(System.in);
        Boolean falg = true;

        while (falg){
            int a = scanner.nextInt();
            if (a>=0){
                count++;
            }else{
                falg=false;
            }
        }

        System.out.println(count);
}}
